package pe.gob.sunarp.entidad;

import java.io.Serializable;
import javax.persistence.*;
import java.math.BigDecimal;
import java.util.Date;
import java.util.Set;


/**
 * The persistent class for the TA_DIAR_CAJA database table.
 * 
 */
@Entity
@Table(name="TA_DIAR_CAJA")
public class TaDiarCaja implements Serializable {
	private static final long serialVersionUID = 1L;
	private long idDiar;
	private String coCaja;
	private BigDecimal coEmplCaje;
	private BigDecimal coEmplTeso;
	private String coRegi;
	private String coSede;
	private String coZona;
	private String deCaja;
	private Date fhAper;
	private Date fhAperCaje;
	private Date fhCierCaje;
	private Set<TaBill> taBills;
	private Set<TaCaja> taCajas;

    public TaDiarCaja() {
    }


	@Id
	@GeneratedValue(strategy=GenerationType.AUTO)
	@Column(name="ID_DIAR", unique=true, nullable=false)
	public long getIdDiar() {
		return this.idDiar;
	}

	public void setIdDiar(long idDiar) {
		this.idDiar = idDiar;
	}


	@Column(name="CO_CAJA", nullable=false, length=2)
	public String getCoCaja() {
		return this.coCaja;
	}

	public void setCoCaja(String coCaja) {
		this.coCaja = coCaja;
	}


	@Column(name="CO_EMPL_CAJE")
	public BigDecimal getCoEmplCaje() {
		return this.coEmplCaje;
	}

	public void setCoEmplCaje(BigDecimal coEmplCaje) {
		this.coEmplCaje = coEmplCaje;
	}


	@Column(name="CO_EMPL_TESO")
	public BigDecimal getCoEmplTeso() {
		return this.coEmplTeso;
	}

	public void setCoEmplTeso(BigDecimal coEmplTeso) {
		this.coEmplTeso = coEmplTeso;
	}


	@Column(name="CO_REGI", length=2)
	public String getCoRegi() {
		return this.coRegi;
	}

	public void setCoRegi(String coRegi) {
		this.coRegi = coRegi;
	}


	@Column(name="CO_SEDE", length=2)
	public String getCoSede() {
		return this.coSede;
	}

	public void setCoSede(String coSede) {
		this.coSede = coSede;
	}


	@Column(name="CO_ZONA", length=2)
	public String getCoZona() {
		return this.coZona;
	}

	public void setCoZona(String coZona) {
		this.coZona = coZona;
	}


	@Column(name="DE_CAJA", length=30)
	public String getDeCaja() {
		return this.deCaja;
	}

	public void setDeCaja(String deCaja) {
		this.deCaja = deCaja;
	}


    @Temporal( TemporalType.DATE)
	@Column(name="FH_APER", nullable=false)
	public Date getFhAper() {
		return this.fhAper;
	}

	public void setFhAper(Date fhAper) {
		this.fhAper = fhAper;
	}


    @Temporal( TemporalType.DATE)
	@Column(name="FH_APER_CAJE")
	public Date getFhAperCaje() {
		return this.fhAperCaje;
	}

	public void setFhAperCaje(Date fhAperCaje) {
		this.fhAperCaje = fhAperCaje;
	}


    @Temporal( TemporalType.DATE)
	@Column(name="FH_CIER_CAJE")
	public Date getFhCierCaje() {
		return this.fhCierCaje;
	}

	public void setFhCierCaje(Date fhCierCaje) {
		this.fhCierCaje = fhCierCaje;
	}


	//bi-directional many-to-one association to TaBill
	@OneToMany(mappedBy="taDiarCaja")
	public Set<TaBill> getTaBills() {
		return this.taBills;
	}

	public void setTaBills(Set<TaBill> taBills) {
		this.taBills = taBills;
	}
	

	//bi-directional many-to-one association to TaCaja
	@OneToMany(mappedBy="taDiarCaja")
	public Set<TaCaja> getTaCajas() {
		return this.taCajas;
	}

	public void setTaCajas(Set<TaCaja> taCajas) {
		this.taCajas = taCajas;
	}
	
}